Using ON TIMER
By Al Staffieri Jr.


You can't have more than one timer active at the same time. Once you make a new timer, it erases the first one. You can change the timer once the first timer is executed like this:

ON TIMER time
 do this
 do that
 ON TIMER differentTime GOTOCARD card
END TIMER

In the example above, the second TIMER will delete the first one, but not until the first timer is activated, so you might not need it anymore.

-----

A single line timer executes only once. This will beep once after 5 seconds:
  ON TIMER 500 BEEP

A multi-line timer executes over and over. This will beep every 5 seconds while you're on the same card.
  ON TIMER 500
    BEEP
  END TIMER

If you use a negative number for the time, the timer will be global (will work even after you switch cards). This will beep once after 5 seconds even if you go to another card before 5 seconds has passed:
  ON TIMER -500 BEEP

This will beep every 5 seconds even if you go to another card:
  ON TIMER -500
    BEEP
  END TIMER

To make a multi-line timer execute only once, put a TIMER OFF as the last command in the TIMER code
  ON TIMER 500
    BEEP
    TIMER OFF
  END TIMER

You can also use TIMER OFF in any button, card, or other script to turn off the timer at any time.
